// To parse this JSON data, do
//
//     final juBoDepermentModel = juBoDepermentModelFromJson(jsonString);

import 'dart:convert';

JuBoDepermentModel juBoDepermentModelFromJson(String str) => JuBoDepermentModel.fromJson(json.decode(str));

String juBoDepermentModelToJson(JuBoDepermentModel data) => json.encode(data.toJson());

class JuBoDepermentModel {
  JuBoDepermentModel({
    this.errMsg,
    this.reObj,
    this.success,
  });

  String errMsg;
  ReObj reObj;
  int success;

  factory JuBoDepermentModel.fromJson(Map<String, dynamic> json) => JuBoDepermentModel(
    errMsg: json["ErrMsg"],
    reObj: ReObj.fromJson(json["ReObj"]),
    success: json["Success"],
  );

  Map<String, dynamic> toJson() => {
    "ErrMsg": errMsg,
    "ReObj": reObj.toJson(),
    "Success": success,
  };
}

class ReObj {
  ReObj({
    this.depList,
    this.userList,
  });

  List<DepList> depList;
  dynamic userList;

  factory ReObj.fromJson(Map<String, dynamic> json) => ReObj(
    depList: List<DepList>.from(json["DepList"].map((x) => DepList.fromJson(x))),
    userList: json["UserList"],
  );

  Map<String, dynamic> toJson() => {
    "DepList": List<dynamic>.from(depList.map((x) => x.toJson())),
    "UserList": userList,
  };
}

class DepList {
  DepList({
    this.id,
    this.numberOfEmployees,
    this.parentId,
    this.roleName,
    this.userId,
  });

  int id;
  int numberOfEmployees;
  int parentId;
  String roleName;
  int userId;

  factory DepList.fromJson(Map<String, dynamic> json) => DepList(
    id: json["ID"],
    numberOfEmployees: json["NumberOfEmployees"],
    parentId: json["ParentId"],
    roleName: json["RoleName"],
    userId: json["UserID"],
  );

  Map<String, dynamic> toJson() => {
    "ID": id,
    "NumberOfEmployees": numberOfEmployees,
    "ParentId": parentId,
    "RoleName": roleName,
    "UserID": userId,
  };
}
